﻿@model IEnumerable<Pescar2013ShopYourAppliances.Models.Producto> 

@{ 
    Layout = "~/Views/Shared/_layout.cshtml";
    ViewBag.Title = "Index"; 
} 

<!---<div ALING="center">portal cliente---> 

<br />
        <table class="table table-hover"> 
        <tr> 
        <th> 
        @Html.DisplayNameFor(model => model.nombre) 
        </th> 
        <th> 
        @Html.DisplayNameFor(model => model.modelo) 
        </th> 
        <th> 
        @Html.DisplayNameFor(model => model.marca) 
        </th> 
        <th> 
        @Html.DisplayNameFor(model => model.precio) 
        </th> 
        <th> 
        @Html.DisplayNameFor(model => model.descripcion) 
        </th> 
        <th> 
        @Html.DisplayNameFor(model => model.url) 
        </th> 
        <th></th> 
        </tr> 

        @foreach (var item in Model) { 
        <tr> 
        <td> 
            <button class="btn btn-primary btn-lg" data-toggle="modal" data-target="#myModal">
  @item.nombre
</button>

<!-- Modal -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
        <h2 class="modal-title" id="myModalLabel">Detalles</h2>
      </div>
     <div class="modal-body">
                                <h3>Nombre</h3>
                             <br />
                                <p>@item.nombre</p>
                            <br />
                                <h3>Modelo</h3>
                            <br />
                                <p>@item.modelo</p>
                            <br />
                                <h3>Precio</h3>
                            <br />
                                <p>@item.precio</p>
                            <br />
                                <h3>Descripcion</h3>
                            <br />
                                <p>@item.descripcion</p>
                            <br />
                                <h3>Imagen</h3>
                            <br />
                                <img src="@item.url" class="img-rounded" title="@item.nombre" />
                            <br />
                        </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal">Ok</button>
      </div>
    </div><!-- /.modal-content -->
  </div><!-- /.modal-dialog -->
</div><!-- /.modal -->
                    
                
        </td> 
        <td> 
        @Html.DisplayFor(modelItem => item.modelo) 
        </td> 
        <td> 
        @Html.DisplayFor(modelItem => item.marca) 
        </td> 
        <td> 
        @Html.DisplayFor(modelItem => item.precio) 
        </td> 
        <td> 
        @Html.DisplayFor(modelItem => item.descripcion) 
        </td> 
        <td> 
        @Html.DisplayFor(modelItem => item.url) 
        </td> 
        </tr> 
        } 
        </table>

 

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>                
<script src="http://netdna.bootstrapcdn.com/bootstrap/2.3.2/js/bootstrap.min.js"></script>
         

